﻿CREATE PROCEDURE [dbo].[DequeueRawOrNull]
	@ServiceName servicenametype
AS
	DECLARE @sql nvarchar(400)
	
	SET @sql = N'RECEIVE TOP (1)  CAST(message_body AS NVARCHAR(MAX)) as messageBodyAsString FROM [' + @ServiceName + N']'

	EXEC sp_executesql @sql